home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Mac Game Programming Gurus / TricksOfTheMacGameProgrammingGurus.iso / More Source / C⁄C++ / Xconq 7.0d37 / source / curses / Makefile.in < prev   
Encoding:
Makefile  |  1995-05-05  |  2.6 KB  |  128 lines  |  [TEXT/R*ch]

  1. # Makefile for curses interface to Xconq.
  2. # Copyright (C) 1991, 1992, 1993, 1994 Stanley T. Shebs.
  3.  
  4. # Xconq is free software; you can redistribute it and/or modify
  5. # it under the terms of the GNU General Public License as published by
  6. # the Free Software Foundation; either version 2, or (at your option)
  7. # any later version.
  8.  
  9. # Where cconq itself lives.
  10.  
  11. prefix = .
  12.  
  13. exec_prefix = $(prefix)
  14. bindir = $(exec_prefix)/bin
  15. # this should be tweaked
  16. libdir = $(srcdir)/../lib
  17. datadir = $(prefix)/lib
  18. mandir = $(prefix)/man
  19. man6dir = $(mandir)/man6
  20. infodir = $(prefix)/info
  21. docdir = $(datadir)/doc
  22.  
  23. srcdir = .
  24.  
  25. krnsrcdir = $(srcdir)/../kernel
  26.  
  27. # Set this for wherever the library directory should be.
  28.  
  29. LIBDIR = $(srcdir)/../lib
  30.  
  31. # Set this for wherever the man page should live.
  32.  
  33. MANDIR = /usr/man/manl
  34.  
  35. SHELL = /bin/sh
  36.  
  37. INSTALL = `cd $(srcdir)/..;pwd`/install.sh -c
  38. INSTALL_PROGRAM = $(INSTALL)
  39. INSTALL_DATA = $(INSTALL)
  40.  
  41. CC = cc
  42.  
  43. CFLAGS = -g
  44.  
  45. CURSES_LIB =  -lcurses -ltermlib
  46.  
  47. # Host and target-dependent makefile fragments come in here.
  48. ####
  49. # End of host and target-dependent makefile fragments.
  50.  
  51. GAME_H = $(krnsrcdir)/game.h \
  52.      $(krnsrcdir)/gvar.def \
  53.      $(krnsrcdir)/utype.def \
  54.      $(krnsrcdir)/mtype.def \
  55.      $(krnsrcdir)/ttype.def \
  56.      $(krnsrcdir)/table.def
  57.  
  58. UNIT_H = $(krnsrcdir)/unit.h \
  59.      $(krnsrcdir)/action.def \
  60.      $(krnsrcdir)/plan.def \
  61.      $(krnsrcdir)/task.def
  62.  
  63. ALL_H = $(krnsrcdir)/conq.h \
  64.     $(krnsrcdir)/config.h \
  65.     $(krnsrcdir)/misc.h \
  66.     $(krnsrcdir)/dir.h \
  67.     $(krnsrcdir)/lisp.h \
  68.     $(krnsrcdir)/module.h \
  69.     $(GAME_H) \
  70.     $(krnsrcdir)/player.h \
  71.     $(krnsrcdir)/side.h \
  72.     $(UNIT_H) \
  73.     $(krnsrcdir)/goal.def \
  74.     $(krnsrcdir)/world.h \
  75.     $(krnsrcdir)/score.h \
  76.     $(krnsrcdir)/history.h \
  77.     $(krnsrcdir)/ai.h
  78.  
  79. C_H = cconq.h
  80.  
  81. OBJ = cconq.o cdraw.o ccmd.o
  82.  
  83. UNIX_CFLAGS = -DUNIX -DUSE_CONSOLE -DXCONQLIB=\"$(LIBDIR)\"
  84.  
  85. # -Dcbreak=crmode
  86.  
  87. ALL_CFLAGS = $(CFLAGS) $(UNIX_CFLAGS) -I$(srcdir) -I$(krnsrcdir)
  88.  
  89. .c.o:
  90.     $(CC) -c $(ALL_CFLAGS) $<
  91.  
  92. all:    cconq
  93.  
  94. cconq: $(OBJ) ../kernel/libconq.a ../kernel/libconqlow.a
  95.     rm -f cconq
  96.     $(CC) -o cconq $(ALL_CFLAGS) $(OBJ) ../kernel/libconq.a ../kernel/libconqlow.a $(CURSES_LIB)
  97.  
  98. ../kernel/libconq.a:
  99.     (cd ../kernel; make libconq.a)
  100.  
  101. ../kernel/libconqlow.a:
  102.     (cd ../kernel; make libconqlow.a)
  103.  
  104. install: all install-only
  105.  
  106. install-only:
  107.     $(INSTALL_PROGRAM) cconq $(prefix)
  108.     $(INSTALL_DATA) $(srcdir)/cconq.6 $(MANDIR)
  109.  
  110. clean:
  111.     rm -f *.o core
  112.     rm -f cconq *.conq *.xconq
  113.  
  114. distclean: clean
  115.     rm -f Makefile config.status
  116.  
  117. extraclean: distclean
  118.     rm -f *~* .*~*
  119.  
  120. realclean: distclean
  121.  
  122. Makefile: Makefile.in $(host_makefile_frag) $(target_makefile_frag)
  123.     $(SHELL) config.status
  124.  
  125. cconq.o:    $(ALL_H) $(C_H)
  126. ccmd.o:        $(ALL_H) $(C_H)
  127. cdraw.o:    $(ALL_H) $(C_H)
  128.